﻿using System.Xml;
using System.Xml.Serialization;

namespace Bpmn.Xml;

/// <remarks/>
[XmlInclude(typeof(SequenceFlow))]
[XmlInclude(typeof(FlowNode))]
[XmlInclude(typeof(Gateway))]
[XmlInclude(typeof(ParallelGateway))]
[XmlInclude(typeof(InclusiveGateway))]
[XmlInclude(typeof(ExclusiveGateway))]
[XmlInclude(typeof(EventBasedGateway))]
[XmlInclude(typeof(ComplexGateway))]
[XmlInclude(typeof(ChoreographyActivity))]
[XmlInclude(typeof(SubChoreography))]
[XmlInclude(typeof(ChoreographyTask))]
[XmlInclude(typeof(CallChoreography))]
[XmlInclude(typeof(Event))]
[XmlInclude(typeof(ThrowEvent))]
[XmlInclude(typeof(IntermediateThrowEvent))]
[XmlInclude(typeof(ImplicitThrowEvent))]
[XmlInclude(typeof(EndEvent))]
[XmlInclude(typeof(CatchEvent))]
[XmlInclude(typeof(StartEvent))]
[XmlInclude(typeof(IntermediateCatchEvent))]
[XmlInclude(typeof(BoundaryEvent))]
[XmlInclude(typeof(Activity))]
[XmlInclude(typeof(Task))]
[XmlInclude(typeof(UserTask))]
[XmlInclude(typeof(ServiceTask))]
[XmlInclude(typeof(SendTask))]
[XmlInclude(typeof(ScriptTask))]
[XmlInclude(typeof(ReceiveTask))]
[XmlInclude(typeof(ManualTask))]
[XmlInclude(typeof(BusinessRuleTask))]
[XmlInclude(typeof(SubProcess))]
[XmlInclude(typeof(Transaction))]
[XmlInclude(typeof(AdHocSubProcess))]
[XmlInclude(typeof(CallActivity))]
[XmlInclude(typeof(DataStoreReference))]
[XmlInclude(typeof(DataObjectReference))]
[XmlInclude(typeof(DataObject))]
[Serializable]
[XmlType(Namespace = "http://www.omg.org/spec/BPMN/20100524/MODEL", TypeName = "tFlowElement")]
[XmlRoot("flowElement", Namespace = "http://www.omg.org/spec/BPMN/20100524/MODEL", IsNullable = false)]
public abstract partial class FlowElement : BaseElement
{
    /// <remarks/>
    [XmlElement("auditing")]
    public Auditing Auditing { get; set; } = default!;

    /// <remarks/>
    [XmlElement("monitoring")]
    public Monitoring Monitoring { get; set; } = default!;

    /// <remarks/>
    [XmlElement("categoryValueRef")]
    public XmlQualifiedName[] CategoryValueRef { get; set; } = default!;

    /// <remarks/>
    [XmlAttribute("name")]
    public string Name { get; set; } = default!;
}
